<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>圣杯布局-flex</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }

        header, footer {
            height: 100px;
            background: pink;
        }

        .main {
            display: flex;
        }

        .content {
            background: red;
            height: 400px;
            flex: auto;
        }

        .left {
            width: 200px;
            background: #7aaed4;
            height: 400px;
            flex: none;

        }

        .right {
            width: 200px;
            background: #5e8809;
            height: 400px;
            flex: none;
        }
    </style>
</head>
<body>

<header>header</header>
<div class="main">
    <div class="left">left</div>
    <div class="content">content</div>
    <div class="right">right</div>
</div>
<footer>footer</footer>

</body>
</html>